package com.mebs.model.reports;

import org.jt.jet.content.JetNamedObject;

/**
 * User: epb
 * Date: 05.02.2009
 * Time: 13:00:21
 */
public enum ReportFormatType implements JetNamedObject {
    DOC(1, "doc"),
    XLS(2, "xls");

    public final int type;
    public final String name;


    ReportFormatType(int type, String name)
    {
        this.type = type;
        this.name = name;
    }

    public static ReportFormatType getObjectByType(int type)
    {
        return ReportFormatType.values()[type - 1];
    }

    public Object getObjectId()
    {
        return type;
    }

    public String getObjectName()
    {
        return name;
    }

    public int getType()
    {
        return type;
    }

    public String getName()
    {
        return name;
    }
}

